Film Noise Filter
kFilmNoiseImageFilterType ('fmns')
The film noise filter alters a single source, simulating some of the effects that are seen on aged film stock. This effect can be used to transform a video source into one that looks like it was shot on film that has suffered the effects of age and mishandling.
The specific features, which can be controlled independently, are:
-
Hairs. These are a simulation of hairs lying on the surface of the film. Each hair is randomly generated, and is colored in a randomly chosen shade of light grey.
-
Scratches. These are vertical or near-vertical one-pixel lines drawn onto the destination image that simulate scratches in the film. Each scratch lasts for a pre-calculated length of time. During its lifespan the scratch's position is randomly perturbed. Shortly before the scratch is removed, it will begin to shorten. The color of the scratches is a randomly chosen shade of light grey.
-
Dust. These simulate dust particles on the surface of the film. Dust particles are drawn using the same algorithm that generates the hairs, but the particles are more tightly curled, and drawn in a darker shade of grey.
-
Film fade. This simulates an overall change in the color of the film stock. Every pixel of the source image is passed through the film fade algorithm, so this can be processor-intensive.
The film noise effect takes a single source and has eight parameters.
Parameters
Use the descriptions below to help you understand what the parameters do. To learn how to use parameter atoms, see
"Adding Video Effects to a QuickTime Movie"
Name
|
Code
|
QTAtom Type
|
Description
|
Hair density
|
'hden'
|
kParameterTypeDataLong
|
This parameter controls the number of hairs that are drawn on each frame and the frequency with which hairs appear. The maximum number of hairs per frame is a randomly generated number between 1 and the value of this parameter. The chance of each hair appearing on a single frame is 1 in (the value of this parameter).
|
Hair length
|
'hlen'
|
kParameterTypeDataLong
|
The maximum length (in pixels) of the hairs being drawn.
|
Scratch density
|
'sden'
|
kParameterTypeDataLong
|
This parameter controls the number of scratches that are drawn on each frame and the frequency with which scratches appear. The maximum number of scratches per frame is a randomly generated number between 1 and the value of this parameter. The chance of each scratch appearing on a single frame is 1 in (the value of this parameter).
|
Scratch duration
|
'sdur'
|
kParameterTypeDataLong
|
The maximum number of frames that each scratch appears for. The actual number of frames for each scratch is a randomly chosen value between 1 and this value plus 20.
|
Scratch width
|
'swid'
|
kParameterTypeDataLong
|
The maximum width, in pixels, of a scratch. The actual width is a randomly chosen number between 1 and this value.
|
Dust density
|
'dden'
|
kParameterTypeDataLong
|
This parameter controls the number of dust particles that are drawn on each frame and the frequency with which dust particles appear. The maximum number of dust particles per frame is a randomly generated number between 1 and the value of this parameter. The chance of each dust particle appearing on a single frame is 1 in (the value of this parameter).
|
Dust size
|
'dsiz'
|
kParameterTypeDataLong
|
For each dust particle, the length in pixels is a random number between 1 and 5, plus the value of the Dust Size parameter.
|
Film fade
|
'fade'
|
kParameterTypeDataEnum
|
The type of film fade effect (if any) to apply. See list below.
|
The Film Fade Enum
The film fade parameter can take one of the following values:
-
None--the destination image is a copy of the source.
-
Sepia tone--the destination is a slightly saturated, monochromatic version of the source, colorized into shades of sepia (a light red-brown).
-
Black and white--the destination is a greyscale version of the source.
-
Faded color film--the destination is a color de-saturated version of the source.
-
1930's color film - the destination is a color super-saturated version of the source.
© 1998 Apple Computer, Inc.| Previous | Chapter Contents | Chapter Top | Next |